//
//  DcIntroModel.m
//  International_Hospital
//
//  Created by 李建强 on 16/7/8.
//  Copyright © 2016年 LiYiLin. All rights reserved.
//

#import "DcIntroModel.h"
#import "NetWorkTool.h"
@implementation DcIntroModel

+(instancetype)dcIntroModelWithDict:(NSDictionary *)dict{
    
    DcIntroModel *model = [[DcIntroModel alloc]init];
    [model setValuesForKeysWithDictionary:dict];
    return model;
}


-(void)dataSuccess:(successBlock)successBlock error:(errorBlock)errorBlock{
    [[NetWorkTool shareManager]POST_RequestWithUrlString:@"http://iosapi.itcast.cn/getIntroduction.json.php" parmas:@{@"doctor_id":@(300000315)} successBloock:^(NSDictionary* responseObject) {
        NSDictionary *tempDic = responseObject[@"data"];
        NSString*data = tempDic[@"introduction"];
        
//        NSMutableArray *muArray = [NSMutableArray array];
        NSLog(@"%@",data);
//        [dataArray enumerateObjectsUsingBlock:^(NSDictionary*  _Nonnull obj, NSUInteger idx, BOOL * _Nonnull stop) {
//            
//            DcIntroModel*model = [DcIntroModel dcIntroModelWithDict:obj];
//            
//            [muArray addObject:model];
//        }];
        if (successBlock) {
//            successBlock(muArray.copy);
        }
        
        
    } failureBlock:^(NSError *error) {
        
        errorBlock();
    }];
    
    
}

-(void)setValue:(id)value forUndefinedKey:(NSString *)key{
    
}

@end
